home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Technotools
/
Technotools (Chestnut CD-ROM)(1993).ISO
/
batch
/
bat
/
ebl.tip
< prev
next >
Wrap
Text File
|
1986-06-21
|
4KB
|
118 lines
Some interesting and useful routines from Larry Weiss for the SEAWARE
Extended Batch Language that's in the XA1 database. If you have some
routines you'd like to share put them up in a message and I'll add them
to the file. If you've not tried EBL yet use the BRO command with a
keyword of EBL to see all the EBL files.
Don Watkins [76703,750]
Fm: Larry Weiss 74415,735
To: all
Has anyone noticed how well Seaware's EBL (Extended Batch Language) and
DOSEDIT complement one another? Turns out that the input to a EBL READ
statement can be generated by DOSEDIT by the up/down arrows. Try this trivial
example as the contents of TEST.BAT:
bat * test.bat
bat -top
bat read .......source file name: %1
bat read ..destination file name: %2
copy %1 %2
bat goto -top
bat exit
The names of the prior input to the reads can be retrieved thanks to NEWKEY.
(Oh, to stop this eternal loop use the Break key). Since EBL is User Supported
(and they certainly ask a reasonable amount of contribution, $30), I would
guess that many of us have "BATware" utilities lying around by now. It would
be interesting to share these (I'm just learning the language, but I'll
certainly publish anything useful here that I come up with, especially
anything that would help novices, and friendly EBL front-ends to some of the
DOS commands would seem appropriate!)....LW
PS: User Supported basically means that the software is distributed a lot like
public domain stuff (free), and the documentation has a section imbedded in it
that requests the user to make a contribution to the author of whatever the
program is worth (to the user). A suggested amount is usually specified.
Sometimes further stipulations are present, for example Seaware requires the
$30 from all commercial users of their EBL but leaves the contribution
optional to private users. Sometimes there are incentives to the
contributors, as in the case with EBL, Seaware will send extended
documentation and grant access to a Bulletin Board system that supports their
products.
Fm: Larry Weiss 74415,735
To: all
Here's an interesting "Batware" routine that facilitates use of the DOS RENAME
function, when running with ANSI.SYS, and especially when running with
DOSEDIT:
bat * rename a file
bat begtype
..old name:
..new name: ;
end
bat call -curup | call -cursave
bat call -go1
bat if (%1) <> () type %1;
bat if (%1) = () read %1
bat if (%1) = () goto -quit
bat call -go2
bat if (%2) <> () type %2;
bat if (%2) = () read %2
bat if (%2) = () goto -quit
rename %1 %2
bat exit
bat -go1 | call -currest | return
bat -go2 | call -currest
bat call -curdown | return
bat -quit | call -go2 | exit
bat -curhome | begtype
\1B[H;
end
bat return
bat -curup | begtype
\1B[1A;
end
bat return
bat -curdown | begtype
\1B[1B;
end
bat return
bat -clears | begtype
\1B[2J;
end
bat return
bat -cursave | begtype
\1B[s;
end
bat return
bat -currest | begtype
\1B[u;
end
bat return
You are forewarned about what information is required and don't have to
remember positions of parameters. If running with DOSEDIT you can rename a
long filename without retyping the unchanged parts of the name twice. The only
drawback as is, is that you have to give this file a name other than
RENAME.BAT, say, something like RN.BAT. I'm working on a "SHELL" Batware
routine that will eliminate this bit of awkwardness and hope to have it done
in a couple of weeks. Notice too that you can enter one or both of the
parameters positionally on the line that invokes the BAT routine. I'd like to
hear about suggestions along these lines as to what should be included in that
utility....LW
Press ENTER to continue: